package com.ruoyi.control.service.impl;

import java.util.List;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; //添加
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.control.mapper.MonkeyVehicleHistoryMapper;
import com.ruoyi.control.domain.MonkeyVehicleHistory;
import com.ruoyi.control.service.IMonkeyVehicleHistoryService;

/**
 * 猴车数据历史Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-12-13
 */
@Service
public class MonkeyVehicleHistoryServiceImpl extends ServiceImpl<MonkeyVehicleHistoryMapper, MonkeyVehicleHistory> implements IMonkeyVehicleHistoryService //修改
{
    @Autowired
    private MonkeyVehicleHistoryMapper monkeyVehicleHistoryMapper;

    /**
     * 查询猴车数据历史
     * 
     * @param id 猴车数据历史主键
     * @return 猴车数据历史
     */
    @Override
    public MonkeyVehicleHistory selectMonkeyVehicleHistoryById(String id)
    {
        return monkeyVehicleHistoryMapper.selectMonkeyVehicleHistoryById(id);
    }

    /**
     * 查询猴车数据历史列表
     * 
     * @param monkeyVehicleHistory 猴车数据历史
     * @return 猴车数据历史
     */
    @Override
    public List<MonkeyVehicleHistory> selectMonkeyVehicleHistoryList(MonkeyVehicleHistory monkeyVehicleHistory)
    {
        return monkeyVehicleHistoryMapper.selectMonkeyVehicleHistoryList(monkeyVehicleHistory);
    }

    /**
     * 新增猴车数据历史
     * 
     * @param monkeyVehicleHistory 猴车数据历史
     * @return 结果
     */
    @Override
    public int insertMonkeyVehicleHistory(MonkeyVehicleHistory monkeyVehicleHistory)
    {
        return monkeyVehicleHistoryMapper.insertMonkeyVehicleHistory(monkeyVehicleHistory);
    }

    /**
     * 修改猴车数据历史
     * 
     * @param monkeyVehicleHistory 猴车数据历史
     * @return 结果
     */
    @Override
    public int updateMonkeyVehicleHistory(MonkeyVehicleHistory monkeyVehicleHistory)
    {
        monkeyVehicleHistory.setUpdateTime(DateUtils.getNowDate());
        return monkeyVehicleHistoryMapper.updateMonkeyVehicleHistory(monkeyVehicleHistory);
    }

    /**
     * 批量删除猴车数据历史
     * 
     * @param ids 需要删除的猴车数据历史主键
     * @return 结果
     */
    @Override
    public int deleteMonkeyVehicleHistoryByIds(String[] ids)
    {
        return monkeyVehicleHistoryMapper.deleteMonkeyVehicleHistoryByIds(ids);
    }

    /**
     * 删除猴车数据历史信息
     * 
     * @param id 猴车数据历史主键
     * @return 结果
     */
    @Override
    public int deleteMonkeyVehicleHistoryById(String id)
    {
        return monkeyVehicleHistoryMapper.deleteMonkeyVehicleHistoryById(id);
    }
}
